package com.avocado.base.validator.organization;
import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Target({ElementType.TYPE, ElementType.ANNOTATION_TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Constraint(validatedBy = OrganizationEditCodeValidator.class)
public @interface OrganizationEditCodeValidation {

    String message() default "Two fields combination validation failed,code with different id exist in database ";
    Class<?>[] groups() default {};
    Class<? extends Payload>[] payload() default {};
    String field1();
    String field2();
}
